package com.wn.class30.entity;

import java.io.Serializable;

/**
 * cupon
 * @author 
 */
public class Cupon implements Serializable {
    /**
     * 优惠劵编号
     */
    private Integer cuponId;

    /**
     * 优惠券名
     */
    private String cuponName;

    /**
     *  优惠劵详情
     */
    private String cuponContent;

    /**
     * 优惠劵金额
     */
    private Double cuponMoney;

    /**
     * 优惠劵使用范围
     */
    private String cuponRange;

    /**
     * 优惠劵数量
     */
    private Integer couponNum;

    /**
     * 优惠劵状态
     */
    private Integer cuponStatus;

    /**
     * 优惠劵图片路径
     */
    private String cuponUrl;

    private static final long serialVersionUID = 1L;

    public Integer getCuponId() {
        return cuponId;
    }

    public void setCuponId(Integer cuponId) {
        this.cuponId = cuponId;
    }

    public String getCuponName() {
        return cuponName;
    }

    public void setCuponName(String cuponName) {
        this.cuponName = cuponName;
    }

    public String getCuponContent() {
        return cuponContent;
    }

    public void setCuponContent(String cuponContent) {
        this.cuponContent = cuponContent;
    }

    public Double getCuponMoney() {
        return cuponMoney;
    }

    public void setCuponMoney(Double cuponMoney) {
        this.cuponMoney = cuponMoney;
    }

    public String getCuponRange() {
        return cuponRange;
    }

    public void setCuponRange(String cuponRange) {
        this.cuponRange = cuponRange;
    }

    public Integer getCouponNum() {
        return couponNum;
    }

    public void setCouponNum(Integer couponNum) {
        this.couponNum = couponNum;
    }

    public Integer getCuponStatus() {
        return cuponStatus;
    }

    public void setCuponStatus(Integer cuponStatus) {
        this.cuponStatus = cuponStatus;
    }

    public String getCuponUrl() {
        return cuponUrl;
    }

    public void setCuponUrl(String cuponUrl) {
        this.cuponUrl = cuponUrl;
    }

    @Override
    public boolean equals(Object that) {
        if (this == that) {
            return true;
        }
        if (that == null) {
            return false;
        }
        if (getClass() != that.getClass()) {
            return false;
        }
        Cupon other = (Cupon) that;
        return (this.getCuponId() == null ? other.getCuponId() == null : this.getCuponId().equals(other.getCuponId()))
            && (this.getCuponName() == null ? other.getCuponName() == null : this.getCuponName().equals(other.getCuponName()))
            && (this.getCuponContent() == null ? other.getCuponContent() == null : this.getCuponContent().equals(other.getCuponContent()))
            && (this.getCuponMoney() == null ? other.getCuponMoney() == null : this.getCuponMoney().equals(other.getCuponMoney()))
            && (this.getCuponRange() == null ? other.getCuponRange() == null : this.getCuponRange().equals(other.getCuponRange()))
            && (this.getCouponNum() == null ? other.getCouponNum() == null : this.getCouponNum().equals(other.getCouponNum()))
            && (this.getCuponStatus() == null ? other.getCuponStatus() == null : this.getCuponStatus().equals(other.getCuponStatus()))
            && (this.getCuponUrl() == null ? other.getCuponUrl() == null : this.getCuponUrl().equals(other.getCuponUrl()));
    }

    @Override
    public int hashCode() {
        final int prime = 31;
        int result = 1;
        result = prime * result + ((getCuponId() == null) ? 0 : getCuponId().hashCode());
        result = prime * result + ((getCuponName() == null) ? 0 : getCuponName().hashCode());
        result = prime * result + ((getCuponContent() == null) ? 0 : getCuponContent().hashCode());
        result = prime * result + ((getCuponMoney() == null) ? 0 : getCuponMoney().hashCode());
        result = prime * result + ((getCuponRange() == null) ? 0 : getCuponRange().hashCode());
        result = prime * result + ((getCouponNum() == null) ? 0 : getCouponNum().hashCode());
        result = prime * result + ((getCuponStatus() == null) ? 0 : getCuponStatus().hashCode());
        result = prime * result + ((getCuponUrl() == null) ? 0 : getCuponUrl().hashCode());
        return result;
    }

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append(getClass().getSimpleName());
        sb.append(" [");
        sb.append("Hash = ").append(hashCode());
        sb.append(", cuponId=").append(cuponId);
        sb.append(", cuponName=").append(cuponName);
        sb.append(", cuponContent=").append(cuponContent);
        sb.append(", cuponMoney=").append(cuponMoney);
        sb.append(", cuponRange=").append(cuponRange);
        sb.append(", couponNum=").append(couponNum);
        sb.append(", cuponStatus=").append(cuponStatus);
        sb.append(", cuponUrl=").append(cuponUrl);
        sb.append(", serialVersionUID=").append(serialVersionUID);
        sb.append("]");
        return sb.toString();
    }
}